Comments

Formula comments are notes that are included with a formula to explain its design and operation. Comments do not print, and they do not affect the formula; they appear only in the Formula Editor.

Basic syntax (Rem)

Usage

Rem text

The text that follows the operator is a comment.

Examples

The following examples are applicable to Basic syntax:

Rem This formula returns the total number of days worked in a year.

Comment is on a new line on its own.

formula = TotalDays : Rem Total number of days worked in a year.

Comment follows a formula statement and a colon.

formula = TotalDays : Rem This formula returns the total number of days _

                          worked in a year.

Comment follows a formula statement and a colon, and it uses the line continuation character to continue onto the next line.

Comments
Related topics

Comments (Basic syntax)

Basic syntax (')

Usage

' text

The text that follows the operator is a comment.

Examples

The following examples are applicable to Basic syntax:

' This formula returns the total number of days worked in a year.

Comment is on a new line on its own.

formula = TotalDays 'Total number of days worked in a year.

Comment follows a formula statement.

formula = TotalDays 'This formula returns the total number of days _

                     worked in a year.

Comment follows a formula statement, and it uses the line continuation character to continue onto the next line.

Comments
Related topics

Comments (Basic syntax)

Crystal syntax (//)

Usage

// text

The text that follows the operator is a comment; it is not treated as part of a formula, and it does not print.

Examples

The following examples are applicable to Crystal syntax:

{file.SALES} - {file.COST}

// calculates the gross profit

{file.SALES} - {file.COST} is the formula; the Formula Editor ignores everything else.

({file.SALES} - {file.QUOTA}) *.06

// calculates sales commission

({file.SALES} - {file.QUOTA}) * .06 is the formula; the Formula Editor ignores everything else.

//what follows is

//a formula. Note that when

//we force the line break we have

//to begin each new line with a

//comment operator.

If {file.COST} > {file.SELL PRICE} Then "Loss" Else "";

//That was a formula

All commented lines that appear before or after the formula are ignored.

Comments
Related topics

Comments (Crystal syntax)



Seagate Software IMG Holdings, Inc.
http://www.seagatesoftware.com
Support services:
http://support.seagatesoftware.com